import { createApp } from 'vue'
import { createPinia } from 'pinia'
import router from './router'
import App from './App.vue'

// 引入Ant Design Vue
import Antd from 'ant-design-vue'
import 'ant-design-vue/dist/reset.css'

// 引入全局样式
import './styles/global.scss'

// 创建Vue应用实例
const app = createApp(App)

// 使用插件
app.use(createPinia())
app.use(router)
app.use(Antd)

// 初始化用户信息
import { useUserStore } from '@/stores'
const userStore = useUserStore()
userStore.initUserInfo()

// 挂载应用
app.mount('#app')
